<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateSettingWechatsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('setting_wechats', function (Blueprint $table) {
            $table->id();
            $table->integer('setting_id')->unsigned()->comment('系统配置setting表id');
            $table->char('wechat_name',20)->nullable()->comment('公众号名称');
            $table->string('wechat_appid',50)->nullable()->comment('公众号appid');
            $table->string('wechat_secret',50)->nullable()->comment('公众号appSecret');
            $table->string('wechat_logo',255)->nullable()->comment('公众号logo');
            $table->string('wechat_qrcode',255)->nullable()->comment('公众号二维码');
            $table->string('wechat_token',50)->nullable()->comment('公众号通信token令牌');
            $table->string('wechat_encoding_key',50)->nullable()->comment('公众号通信加密密钥');
            $table->text('wechat_navs')->nullable()->comment('公众号菜单');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('setting_wechats');
    }
}
